﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ILexAnalysis
{
    /// <summary>
    /// 词法分析的接口
    /// </summary>
    public interface ILexAnalysis
    {
        /// <summary>
        /// 获取下一个单词符号
        /// </summary>
        /// <returns>下一个单词符号</returns>
        string GetNextToken();

        /// <summary>
        /// 获取当前单词符号的SYN
        /// </summary>
        /// <returns>当前单词符号的SYN</returns>
        int GetSym();

        /// <summary>
        /// 词法分析是否成功
        /// </summary>
        /// <returns>是否成功</returns>
        bool Success();

        /// <summary>
        /// 获取当前行号
        /// </summary>
        /// <returns>当前行号</returns>
        int GetLine();
    }
}
